package com.xnx.bincker.leader.exception.data;

import org.springframework.validation.FieldError;

import java.util.Collection;

/**
 * 表单验证异常
 */
public class ValidationException extends DataException {
    private Object data;
    public ValidationException(Collection<FieldError> fieldErrors) {
        this("数据验证失败", fieldErrors);
    }
    public ValidationException(String message, Collection<FieldError> fieldErrors) {
        super(200, message, message, null);
        this.data = fieldErrors;
    }
}
